package com.easylinkin.linkappapi.messagecenter.entity.enumType;

/**
 * 
 * @author yan
 * @date 2022年7月26日下午5:42:10
 * @Description 消息提醒类型枚举
 */

public enum messageTypeEnum {

	/**
	 * 消息中心枚举
	 */
	UNKNOWN(0,"未知类型"),//未知类型
	BOX(1,"配电箱"),//配电箱
	DANGER(2,"隐患"),//隐患
	DEVICE_WARN(3,"设备预警"), //设备预警
	QUALITY_APPRAISING_EXCELLENT(4,"质量评优"),//质量评优
	QUALITY(5,"质量"),
	;

	private int _value;
	private String _name;

	private messageTypeEnum(int value, String name) {
		_value = value;
		_name = name;
	}

	public int value() {
		return _value;
	}

	public String getName() {
		return _name;
	}

	public static messageTypeEnum getMsgEnum(Integer type) {
		for (messageTypeEnum c : messageTypeEnum.values()) {
			if (c._value == type.intValue()) {
				return c;
			}
		}
		return null;
	}
}
